<template>
	<view>
		<view class="">
			<view class="m-h1" style="text-align: center;">
				清单详情
			</view>
			<view class="" @tap="toBack()">
				<image class="nav-margin-back-img" src="../../static/back.png" mode="widthFix"></image>
			</view>
		</view>	
		
		<view class="nav-margin-top">
			
			<view class="content " style="padding-bottom: 10rpx;">
				<view class="o-4-font-2">
					<view class="">
						沙葛小学一期项目需求清单
					</view>
					<view class="">
						<text class="o-4-font-3" style="margin-right: 20rpx;">自建</text>
						<text class="o-4-font-4">2021-01-12 13:09</text>
					</view>
					<view class="" style="display: flex;justify-content: space-between;">
						<view class="o-5-font-1" style="padding-top: 20rpx;">
							2个商品
						</view>
						<view @tap="toOrderList3" class="o-5-set-btn">
							<text style="position: relative;top: 10rpx;">交付设置</text>
						</view>
					</view>
				</view>
			</view>
			<view class="o-bg-1"></view>
			
			<view class="" style="padding-bottom: 20rpx;">
				<view class="content" style="padding-top: 20rpx;padding-bottom: 20rpx;">
					<view class="" style="display: flex;justify-content: space-between;">
						<view class="" style="display: flex;">
							<view  v-if="isCheck2" class="" style="display: flex;align-items: center;">
								<image @tap="isCheck2=!isCheck2" style="width: 48rpx;height: 48rpx;" src="../../static/check-1.png" mode="widthFix"></image>
							</view>
							
							<view  v-if="!isCheck2" class="" style="display: flex;align-items: center;">
								<image @tap="isCheck2=!isCheck2" style="width: 48rpx;height: 48rpx;" src="../../static/none.png" mode="widthFix"></image>
							</view>
							<view class="" style="margin-left: 20rpx;">
								<view class="">
									<text class="o-l-font-1" style="margin-right: 10rpx;">第一批交付</text>
									<text class="o-l-font-3">子订单</text>
									<view class="o-l-font-2">
										交付时间：2021.01.30
									</view>
								</view>
							</view>
							
						</view>
						<view class="" style="position: relative;top:20rpx">
							<text class="o-l-font-4" style="margin-right: 10rpx;">1件</text>
							<image style="width: 32rpx;height: 8rpx;position: relative;top: 8rpx;" src="../../static/pic1.png" mode="widthFix"></image>
						</view>
					</view>
				</view>
				
				<view class="o-bg-3"></view>
				
				<view class="content">
					
					<view class="" style="display: flex;margin-top: 20rpx;">
						
					
						<view class="" style="margin: 0 16rpx;">
							<image style="width: 248rpx;height: 248rpx;" src="../../static/pic.png" mode="widthFix"></image>
						</view>
						<view class="" style="width: 400rpx;">
							<view class="o-5-font-1">
								外墙保温砌块 
							</view>
							<view class="o-5-font-1">
								规格(LxBxH)：600x200x250 
							</view>
							<view class="o-5-font-1">
								等级:B05A3.5   平面
							</view>
							<view class="">
								<text class="o-5-font-2">3-5天</text>
								<text class="o-5-font-2">40m³起订</text>
								<text class="o-5-font-2">70%定金</text>
							</view>
							<view class="" style="display: flex;justify-content: space-between;margin-top: 60rpx;">
								<view class="">
									<text class="o-5-font-3">¥89.0</text>
									<text class="o-5-font-4">/m³</text>
								</view>
								<view class="" style="display: flex;">
									<view @tap="value1--" class="" v-if="value1>1">
										<image style="width: 48rpx;height: 48rpx;" src="../../static/o-sub.png" mode=""></image>
									</view>
									<view class="" v-else>
										<image style="width: 48rpx;height: 48rpx;" src="../../static/o-sub-1.png" mode=""></image>
									</view>
									<view class="o-5-font-5">
										<text style="position: relative;top: 8rpx;">{{value1}}</text> 
									</view>
									<view class="">
										<image @tap="value1++" style="width: 48rpx;height: 48rpx;" src="../../static/o-add.png" mode="widthFix"></image>
									</view>
								</view>
								
							</view>
						</view>
					</view>
				</view>
			</view>
			
			
			<view class="o-bg-1"></view>
			
			<view class="">
				<view class="content" style="padding-top: 20rpx;padding-bottom: 20rpx;">
					<view class="" style="display: flex;justify-content: space-between;">
						<view class="" style="display: flex;">
							<view  v-if="isCheck1" class="" style="display: flex;align-items: center;">
								<image @tap="isCheck1=!isCheck1" style="width: 48rpx;height: 48rpx;" src="../../static/check-1.png" mode="widthFix"></image>
							</view>
							
							<view  v-if="!isCheck1" class="" style="display: flex;align-items: center;">
								<image @tap="isCheck1=!isCheck1" style="width: 48rpx;height: 48rpx;" src="../../static/none.png" mode="widthFix"></image>
							</view>
							<view class="" style="margin-left: 20rpx;">
								<view class="">
									<text class="o-l-font-1" style="margin-right: 10rpx;">第二批交付</text>
									<text class="o-l-font-3">子订单</text>
									<view class="o-l-font-2">
										交付时间：2021.01.30
									</view>
								</view>
							</view>
							
						</view>
						<view class="" style="position: relative;top:20rpx">
							<text class="o-l-font-4" style="margin-right: 10rpx;">2件</text>
							<image style="width: 32rpx;height: 8rpx;position: relative;top: 8rpx;" src="../../static/pic1.png" mode="widthFix"></image>
						</view>
					</view>
				</view>
				
				<view class="o-bg-3"></view>
				
				<view class="content" style="padding-bottom: 20rpx;">
					<view class="" style="display: flex;margin-top: 20rpx;">
						<view class="" style="margin: 0 16rpx;">
							<image style="width: 248rpx;height: 248rpx;" src="../../static/pic.png" mode="widthFix"></image>
						</view>
						<view class="" style="width: 400rpx;">
							<view class="o-5-font-1">
								外墙保温砌块 
							</view>
							<view class="o-5-font-1">
								规格(LxBxH)：600x200x250 
							</view>
							<view class="o-5-font-1">
								等级:B05A3.5   平面
							</view>
							<view class="">
								<text class="o-5-font-2">3-5天</text>
								<text class="o-5-font-2">40m³起订</text>
								<text class="o-5-font-2">70%定金</text>
							</view>
							<view class="" style="display: flex;justify-content: space-between;margin-top: 60rpx;">
								<view class="">
									<text class="o-5-font-3">¥89.0</text>
									<text class="o-5-font-4">/m³</text>
								</view>
								<view class="" style="display: flex;">
									<view @tap="value2--" class="" v-if="value2>1">
										<image style="width: 48rpx;height: 48rpx;" src="../../static/o-sub.png" mode=""></image>
									</view>
									<view class="" v-else>
										<image style="width: 48rpx;height: 48rpx;" src="../../static/o-sub-1.png" mode=""></image>
									</view>
									<view class="o-5-font-5">
										<text style="position: relative;top: 8rpx;">{{value2}}</text> 
									</view>
									<view class="">
										<image @tap="value2++" style="width: 48rpx;height: 48rpx;" src="../../static/o-add.png" mode="widthFix"></image>
									</view>
								</view>
								
							</view>
						</view>
					</view>
				</view>
			
			
			<view class="content" style="padding-bottom: 20rpx;margin-bottom: 220rpx;">
				<view class="" style="display: flex;margin-top: 20rpx;">
					<view class="" style="margin: 0 16rpx;">
						<image style="width: 248rpx;height: 248rpx;" src="../../static/pic.png" mode="widthFix"></image>
					</view>
					<view class="" style="width: 400rpx;">
						<view class="o-5-font-1">
							外墙保温砌块 
						</view>
						<view class="o-5-font-1">
							规格(LxBxH)：600x200x250 
						</view>
						<view class="o-5-font-1">
							等级:B05A3.5   平面
						</view>
						<view class="">
							<text class="o-5-font-2">3-5天</text>
							<text class="o-5-font-2">40m³起订</text>
							<text class="o-5-font-2">70%定金</text>
						</view>
						<view class="" style="display: flex;justify-content: space-between;margin-top: 60rpx;">
							<view class="">
								<text class="o-5-font-3">¥89.0</text>
								<text class="o-5-font-4">/m³</text>
							</view>
							<view class="" style="display: flex;">
								<view @tap="value3--" class="" v-if="value3>1">
									<image style="width: 48rpx;height: 48rpx;" src="../../static/o-sub.png" mode=""></image>
								</view>
								<view class="" v-else>
									<image style="width: 48rpx;height: 48rpx;" src="../../static/o-sub-1.png" mode=""></image>
								</view>
								<view class="o-5-font-5">
									<text style="position: relative;top: 8rpx;">{{value3}}</text> 
								</view>
								<view class="">
									<image @tap="value3++" style="width: 48rpx;height: 48rpx;" src="../../static/o-add.png" mode="widthFix"></image>
								</view>
							</view>
							
						</view>
					</view>
				</view>
			</view>
			
			</view>
	
		<view class="o-bottom" style="display: flex;justify-content: space-between;">
			
			<view class="" style="display: flex;margin-left: 20rpx;">
				<view  v-if="isCheck3" class="" style="display: flex;align-items: center;">
					<image @tap="isCheck" style="width: 48rpx;height: 48rpx;" src="../../static/check-1.png" mode="widthFix"></image>
				</view>
				
				<view  v-if="!isCheck3" class="" style="display: flex;align-items: center;">
					<image @tap="isCheck" style="width: 48rpx;height: 48rpx;" src="../../static/none.png" mode="widthFix"></image>
				</view>
				<view class="" style="padding-top: 35rpx;display: flex;">
					<view class="o-4-font-4" style="margin-left: 6rpx;margin-right: 20rpx;">
						全选
					</view>
					<text class="o-4-font-8">总计：</text>
					<text class="o-4-font-9">¥267.0</text>
				</view>
			
			</view>
			
			<view class="" style="display: flex;">
				<view>
					<button  type="default" style="width: 160rpx;height: 96rpx;margin-right: 20rpx;">
						<text class="o-4-font-7" style="position: relative;top30rpx">分享</text>
						
						</button>
				</view>
				<view >
					<button @click="toPay()" class="" type="default" style="background-color: #1B4098; width: 160rpx;height: 96rpx;">
						<text class="o-4-font-6" style="position: relative;top30rpx">立即支付</text>
						</button>
					</view>
				</view>
			</view>
			
		</view>
		
		
		
		
	</view>
</template>

<script>
	export default {
		data() {
			return {
				value1:1,
				value2:3,
				value3:3,
				isCheck1:false,
				isCheck2:false,
				isCheck3:false,
			}
		},
		watch:{
			isCheck:function(){
				if(isCheck1&&isCheck2){isCheck3=true;}
			}
		},
		methods: {
			toPay:function(){
				uni.navigateTo({
					url:'../order-compute/order-compute'
				})
			},
			toOrderList3:function(){
				uni.navigateTo({
					url:'../order-list-3/order-list-3'
				})
			},
			toBack:function(){
				console.log(1)
				uni.navigateBack({
					delta: 1 //返回上一级页面
				})
			},
			isCheck:function(){
				this.isCheck3 = !this.isCheck3;
				if(this.isCheck3){
					this.isCheck1=true;
					this.isCheck2=true;
				}else{
					this.isCheck1=false;
					this.isCheck2=false;
				}
			}
		}
	}
</script>

<style lang="less" scoped>
@import url('../../style.less');
@import url('order-list-1.less');

</style>
